home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Libris Britannia 4
/
science library(b).zip
/
science library(b)
/
PROGRAMM
/
ASSEMBLE
/
H055.ZIP
/
DEMO
/
IGC0011.ALC
< prev
next >
Wrap
Text File
|
1987-06-06
|
2KB
|
96 lines
TITLE 'IGC0011 - PC/370 MVS TIMER TYPE 4 SVC'
* PGMID. IGC0011.ALC (LINKED AS IGC0011.MOD)
* AUTHOR. DON HIGGINS.
* DATE. 06/03/87
* REMARKS. PC/370 MVS SHELL TIMER TYPE 4 SVC MODULE DYNAMICALLY
* LOADED AND EXECUTED BY SVC HANDLER
*
* MAINTENANCE.
*
* 06/03/87 COPIED FROM IGC1013 AND CODED
* 06/06/87 FINISH CODING OPTIONS
*
IGC0011 CSECT
USING *,R6
ST R14,IGCSAV
LR R3,R0 SAVE ADDR TO STORE TOD/TIME IN MICROSECONDS
STC R1,OPTIONS
NI OPTIONS,X'0F'
BZ TUNITS R0 = TOD TIMER UNITS (26. MICROSECONDS)
CLI OPTIONS,X'01'
BE T01SEC R0 = TOD 0.01 SECONDS
CLI OPTIONS,X'02'
BE TPDEC R0 = TOD PACKED (HHMMSSTH)
CLI OPTIONS,X'03'
BE TMICRO A(R0) = DOUBLE WORD TOD (BIT 51 = MSEC)
CLI OPTIONS,X'04'
BE TCLOCK A(R0) = TOD CLOCK
LA R15,4 EXIT WITH ERROR IF NO OPTION MATCH
L R14,IGCSAV
BR R14
TUNITS EQU *
L R15,=V(TIMER) USE L370.LIB TIMER.ALC SUBROUTINE
AR R15,R6 RELOCATE
BALR R14,R15
LR R1,R0
SR R0,R0
M R0,=A(1000000/26) CONVERT 0.01 SEC TO TU'S (CRUDE!)
LR R0,R1
B IGCEXT
T01SEC EQU *
L R15,=V(TIMER) USE L370.LIB TIMER.ALC SUBROUTINE
AR R15,R6 RELOCATE
BALR R14,R15
B IGCEXT
TPDEC EQU *
SVC PCTIME
ST R0,WORK
SR R0,R0
IC R0,WORK HOURS
BAL R1,CVT
STC R0,WORK
IC R0,WORK+1 MINUTES
BAL R1,CVT
STC R0,WORK+1
IC R0,WORK+2 SECONDS
BAL R1,CVT
STC R0,WORK+2
IC R0,WORK+3 100TH SECONDS
BAL R1,CVT
STC R0,WORK+3
L R0,WORK
B IGCEXT
CVT EQU * CONVERT R0 NN BINARY TO NN DEC
CVD R0,PWORK
MP PWORK,=P'10'
IC R0,PWORK+6
BR R1
TMICRO EQU *
MVC 0(8,R3),=XL8'00' STORE ZEROS FOR NOW
B IGCEXT
TCLOCK EQU *
MVC 0(8,R3),=XL8'00' STORE ZEROS FOR NOW
B IGCEXT
IGCEXT EQU *
SR R15,R15
L R14,IGCSAV
BR R14
*
* DATA
*
PWORK DC D'0'
WORK DC F'0'
PCTIME EQU 18
IGCSAV DC A(0) SAVE RETURN
OPTIONS DC X'00'
R0 EQU 0
R1 EQU 1
R2 EQU 2
R3 EQU 3
R4 EQU 4
R5 EQU 5
R6 EQU 6
R14 EQU 14
R15 EQU 15
END